package com.ccrfid.rmc6.service.poi;

import com.ccrfid.rmc6.appconfig.exception.pojo.AppException;
import com.ccrfid.rmc6.entity.poi.PoiLocationEntity;
import com.ccrfid.rmc6.pojo.dto.LocationBindPersonnelDto;
import com.ccrfid.rmc6.pojo.dto.LocationPersonnelDto;
import com.ccrfid.rmc6.repository.search.SearchCriteria;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.domain.Sort;

import java.util.List;

public interface PoiLocationService {
    List<PoiLocationEntity> getPoiLocationList(SearchCriteria criteria, Sort sort);
    //
    Page<PoiLocationEntity> getPoiLocationPageList(SearchCriteria criteria, Pageable pageable);
    //
    List<PoiLocationEntity> getAllLocations();
    //
    PoiLocationEntity getPoiLocationById(Long locationId);
    //
    PoiLocationEntity createPoiLocation(PoiLocationEntity entity) throws AppException;
    //
    PoiLocationEntity updatePoiLocation(Long locationId, PoiLocationEntity entity) throws AppException;
    //
    int deletePoiLocations(List<Long> idList);
    //
    PoiLocationEntity bindLocationOrg(Long locationId, Long orgId) throws AppException;
    //
    PoiLocationEntity unBindLocationOrg(Long locationId) throws AppException;
    //
    Page<LocationPersonnelDto> getPersonnelsInfoInLocation(Long locationId, Pageable pageable);
    //
    Page<LocationPersonnelDto> getActualPersonnelsInfoInLocation(Long locationId, Integer personnelType, Pageable pageable);
    //
    LocationBindPersonnelDto getBindPersonnelsInfoInLocation(Long locationId);
}
